{foreach name="withImgTpl" item="vo"}
    <script id="{$vo.tplId}" type="text/html">
        {{# if (d.{$vo.field}) { }}
        <div class="lazy-images">
            <img lay-src="{{d.{$vo.field}}}" builder-event="photos" class="lazy-images"/>
        </div>
        {{# }else{ }}
        -
        {{# } }}
    </script>
{/foreach}

{foreach name="withVideoTpl" item="vo"}
    <script id="{$vo.tplId}" type="text/html">
        {{# if (d.{$vo.field}) { }}
        <div class="lazy-video">
            <video src="{{d.{$vo.field}}}" builder-event="video"></video>
        </div>
        {{# }else{ }}
        -
        {{# } }}
    </script>
{/foreach}

{foreach name="fastSort" item="vo"}
    <script id="builderFastSortTpl-{$vo.field}" type="text/html">
        <div class="builder-fast-sort">
            <input type="text" data-filed="{$vo.field}" data-id="{{d.{$builderPk}}}"
                   value="{{d.{$vo.field}}}" class="layui-input" builder-event-blur="sort"/>
        </div>
    </script>
{/foreach}

{foreach name="fastRatio" item="vo"}
    <script id="builderFastRatioTpl-{$vo.field}" type="text/html">
        {{ (d.{$vo.field} * 100).toFixed(2)}}%
    </script>
{/foreach}

{foreach name="friendly" item="vo"}
    <script id="builderFriendlyTpl-{$vo.field}" type="text/html">
        <span class="{{d.{$vo.field} < 0 || d.fx == '-' ? 'text-red' : 'text-green'}}">{{ d.{$vo.field} }}</span>
    </script>
{/foreach}

{foreach name="switch" item="vo"}
    <script id="builderSwitchTpl-{$vo.field}" type="text/html">
        <div class="layui-form builder-fast-sort">
            <input type="checkbox" value="{{d.{$vo.field}}}" lay-filter="builderSwitch" lay-skin="switch"
                   data-filed="{$vo.field}" data-id="{{d.{$builderPk}}}" title="{$vo.switch.text}"
                   {{ d.{$vo.field}== {$vo.switch.checked} ? 'checked' : '' }}>
        </div>
    </script>
{/foreach}